package com.mes.biz.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.mes.common.annotation.Excel;
import com.mes.common.core.domain.BaseEntity;
import com.mes.common.utils.log.annotation.FieldRemark;
import com.mes.common.utils.log.annotation.LogField;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import javax.validation.constraints.NotBlank;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 库存台账对象 biz_product_inventory_book
 * @author hwg
 * @email hwg
 * @date 2023-06-01
 */
@Data
public class BizProductInventoryBook extends BaseEntity<BizProductInventoryBook>
{
    private static final long serialVersionUID = 1L;

    /** 库存 */
    @Excel(name = "库存")
    @LogField
    @FieldRemark(name = "库存",field = "inventoryId")
    private String inventoryId;

    /** 日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "日期", width = 30, dateFormat = "yyyy-MM-dd")
    @LogField
    @FieldRemark(name = "日期",field = "bizDate")
    private Date bizDate;

    /** 日期开始 */
    private String beginBizDate;

    /** 日期结束 */
    private String endBizDate;

    /** 单据编号 */
    @Excel(name = "单据编号")
    @LogField
    @FieldRemark(name = "单据编号",field = "orderNumber")
    private String orderNumber;

    /** 客户 */
    @Excel(name = "客户")
    @LogField
    @FieldRemark(name = "客户",field = "customer")
    private String customer;

    /** 产品型号 */
    @Excel(name = "产品型号")
    @LogField
    @FieldRemark(name = "产品型号",field = "productModel")
    private String productModel;

    /** 辅助单位数量1 */
    @Excel(name = "辅助单位数量1")
    @LogField
    @FieldRemark(name = "辅助单位数量1",field = "assistNumberA")
    private BigDecimal assistNumberA;

    /** 辅助单位数量2 */
    @Excel(name = "辅助单位数量2")
    @LogField
    @FieldRemark(name = "辅助单位数量2",field = "assistNumberB")
    private BigDecimal assistNumberB;

    /** 数量 */
    @LogField
    @FieldRemark(name = "数量",field = "number")
    private BigDecimal number;

    /** 主单位 */
    @LogField
    @FieldRemark(name = "主单位",field = "unit")
    private String unit;

    /** 辅助单位1 */
    @LogField
    @FieldRemark(name = "辅助单位1",field = "assistUnitA")
    private String assistUnitA;

    /** 辅助单位2 */
    @LogField
    @FieldRemark(name = "辅助单位2",field = "assistUnitB")
    private String assistUnitB;

    /** 单价 */
    @LogField
    @FieldRemark(name = "单价",field = "price")
    private BigDecimal price;

    /** 金额 */
    @LogField
    @FieldRemark(name = "金额",field = "amount")
    private BigDecimal amount;

    /** 单据类型1销售单2采购单 */
    @LogField
    @FieldRemark(name = "单据类型1销售单2采购单",field = "orderType")
    private String orderType;

    /** 租户id */
    @NotBlank(message = "租户id不允许为空")
    @LogField
    @FieldRemark(name = "租户id",field = "tenantId")
    private String tenantId;

    /** 仓位 */
    @Excel(name = "仓位")
    private String spaceId;

    /** 默认仓库 */
    @Excel(name = "默认仓库")
    private String warehouseId;

    @LogField
    @FieldRemark(name = "商品id",field = "productId")
    private String productId;


    private String supplierName;
    private String warehouseName;
    private String spaceName;
    private String brand;
    private String spec;
    private String color;
    private String model;
}
